import { librarySizeList } from '@/api/modules/data/library.size';
import { DICT_ENUM } from '@/enum/system';
import { getDictList } from '@/utils/common/dict';
import type { LabeledValue } from 'ant-design-vue/es/select';

export const typeOptions = ref<LabeledValue[]>([]);
export const materialCategoryOptions = ref<LabeledValue[]>([]);
export const getResolutionOptions = ref<LabeledValue[]>([]);
export const listLibrarySizeOptions = ref<any[]>([]);

export const getOptions = async () => {
  getMaterialCategory();
  getTypeOptions();
};

export const getTypeOptions = async () => {
  typeOptions.value = await getDictList(DICT_ENUM.MATERIAL_CATEGORY);
};

export const getMaterialCategory = async () => {
  const data = await getDictList(DICT_ENUM.MATERIAL_TYPE);
  materialCategoryOptions.value = data;
};
